/*
 * DbmsClientHelp.java
 *
 * Created on 2 Июнь 2008 г., 0:45
 */

package dbmsclient;

import java.util.ResourceBundle;

/**
 *
 * @author  makarof
 */
public class DbmsClientHelp extends javax.swing.JDialog {
    
    /** Creates new form DbmsClientHelp */
    public DbmsClientHelp(java.awt.Frame parent, boolean modal) {
        super(parent, modal);
        bundle = getBundle();
        initComponents();
    }
    public void reloadComponents(ResourceBundle bundle) {
        jLabel1.setText(bundle.getString("help"));
        jButton1.setText(bundle.getString("close"));
        DbmsClientHelp.this.setTitle(bundle.getString("help"));
    }
    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    private void initComponents() {//GEN-BEGIN:initComponents

        jScrollPane1 = new javax.swing.JScrollPane();
        jTextArea1 = new javax.swing.JTextArea();
        jLabel1 = new javax.swing.JLabel();
        jButton1 = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);

        jTextArea1.setColumns(20);
        jTextArea1.setEditable(false);
        jTextArea1.setFont(application.Application.getInstance(dbmsclient.DbmsClientApp.class).getContext().getResourceMap(DbmsClientHelp.class).getFont("jTextArea1.font")); // NOI18N
        jTextArea1.setLineWrap(true);
        jTextArea1.setRows(5);
        jTextArea1.setText(application.Application.getInstance(dbmsclient.DbmsClientApp.class).getContext().getResourceMap(DbmsClientHelp.class).getString("jTextArea1.text")); // NOI18N
        jTextArea1.setWrapStyleWord(true);
        jScrollPane1.setViewportView(jTextArea1);

        jLabel1.setFont(application.Application.getInstance(dbmsclient.DbmsClientApp.class).getContext().getResourceMap(DbmsClientHelp.class).getFont("jLabel1.font")); // NOI18N
        jLabel1.setText(application.Application.getInstance(dbmsclient.DbmsClientApp.class).getContext().getResourceMap(DbmsClientHelp.class).getString("jLabel1.text")); // NOI18N

        jButton1.setText(application.Application.getInstance(dbmsclient.DbmsClientApp.class).getContext().getResourceMap(DbmsClientHelp.class).getString("jButton1.text")); // NOI18N
        jButton1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton1ActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel1)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 442, Short.MAX_VALUE)
                    .addComponent(jButton1, javax.swing.GroupLayout.Alignment.TRAILING))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGap(6, 6, 6)
                .addComponent(jLabel1)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 242, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jButton1)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        pack();
    }//GEN-END:initComponents

private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed
   setVisible(false);
}//GEN-LAST:event_jButton1ActionPerformed
    
private java.util.ResourceBundle bundle;

public void setBundle(java.util.ResourceBundle bundle) {
    this.bundle = bundle;
}

public java.util.ResourceBundle getBundle() {
    return this.bundle;
}

    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                DbmsClientHelp dialog = new DbmsClientHelp(new javax.swing.JFrame(), true);
                dialog.addWindowListener(new java.awt.event.WindowAdapter() {
                    public void windowClosing(java.awt.event.WindowEvent e) {
                        System.exit(0);
                    }
                });
                dialog.setVisible(true);
            }
        });
    }
    
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton jButton1;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JTextArea jTextArea1;
    // End of variables declaration//GEN-END:variables
    
}
